package com.wang.lotterysystem.service.dto.activity;

import com.wang.lotterysystem.controller.enums.ActivityStatusEnum;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

@Data
public class ActivityDTO {

    @Schema(description = "活动id")
    private Long activityId;

    @Schema(description = "活动名称")
    private String activityName;

    @Schema(description = "活动描述")
    private String description;

    @Schema(description = "活动状态")
    private ActivityStatusEnum status;

    /**
     * 校验活动是否有效
     */
    public Boolean valid(){
        return this.status.equals(ActivityStatusEnum.RUNNING);
    }
}